/* Definition of the remote add and subtract procedure used by 
   simple RPC example 
   rpcgen will create a template for you that contains much of the code
   needed in this file is you give it the "-Ss" command line arg.
*/

#include "BIC.h"
#include <stdio.h> 
/* Here is the actual remote procedure */
/* The return value of this procedure must be a pointer to int! */
/* we declare the variable result as static so we can return a 
   pointer to it */

int* add_1_svc(int *argp)
{
   static int  result;
   
   printf("Got request: int test \n");
   
   result = *argp + 100;
   
   return(&result);
}

float * fadd_2_svc(float* argp )
{
   static float  result;
   
   printf("Got request: float test \n");
  
   result = *argp + 1.1;
   
   return(&result);
}

char * chartest_3_svc(char * argp)
{
   static char  result;
   
   printf("Got request: char test \n");
   
   result = 'a';
   
   return(&result);
}
